import { createStore } from 'vuex'
import { createApp } from 'vue'
import Vuex from 'vuex'
import defaultState from './state/state'
import mutations from './mutations/mutations'
import getters from './getters/getters'
import actions from './actions/actions'
import user from './modules/user'
import blog from './modules/blog'
import app from './modules/app'
// createApp().use(Vuex)

const isDev = process.env.NODE_ENV === 'development'

export default createStore({
    strict: isDev, //this.$store.state.count = 99; 开发环境限制这样的写法,规范团队
    state: defaultState, //全局模块
    mutations,
    getters,
    actions,
    modules: {
      app,
      // dict,
      user,
      blog,
      // tagsView,
      // permission,
      // settings
    },
  })


// export default createStore({
//   state: {
//   },
//   mutations: {
//   },
//   actions: {
//   },
//   modules: {
//   }
// })
